/**
 * @Description:
 * @Author bianpengfei
 * @create 2021/6/25 9:12
 */
import { createStore, compose, applyMiddleware } from 'redux'
import thunk from 'redux-thunk'
import reducer from './reducer.js'

const composeEnhancers = (typeof window !== 'undefined' && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__) || compose

const store = createStore(
  reducer,
  {
    count: 0
  },
  composeEnhancers(applyMiddleware(thunk))
)
export default store
